package com.zhangj.springcloud.service;

import com.zhangj.springcloud.entites.CommonResult;
import com.zhangj.springcloud.entites.Payment;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;

/**
 * @InterfaceName PaymentService
 * @Description
 * @Author zhangjie
 * @Date 2022/1/15 20:53
 * @Version 1.0
 */

@FeignClient(name = "CLOUD-PAYMENT-SERVICE")
public interface PaymentService {

    @RequestMapping("/payment/get/{id}")
    public CommonResult<Payment> getPaymentById(@PathVariable("id")Long id);

    @RequestMapping("/payment/creat")
    public CommonResult<Payment> creat(@RequestBody Payment payment);
}
